<template>
    <div class="home">
        <h2>当前计数home:{{ counter }}</h2>
        <button @click="up">+1</button>
        <button @click="down">-1</button>
    </div>
</template>
<script>
import usecounter from './hooks/usecounter';
import { onMounted } from "vue"
export default {
    setup() {
        const { counter, up, down } = usecounter()
        return {
            counter,
            up,
            down,
        }
    }
}
</script>
<style scoped lang="less"></style>